import request from '@/config/request'



export function departmentpage(query) {
    return request({
        url: '/basic/department-info/page',
        method: 'get',
        params: query
    })
}

export function departmentlist() {
    return request({
        url: '/basic/department-info/list',
        method: 'get'
    })
}

// 新增菜单
export function addDepartment(data) {
    return request({
        url: '/basic/department-info',
        method: 'post',
        data: data
    })
}

// 修改菜单
export function updateDepartment(data) {
    return request({
        url: '/basic/department-info',
        method: 'put',
        data: data
    })
}
export function getDepartment(id) {
    return request({
        url: '/basic/department-info/'+id,
        method: 'get',
    })
}

// 删除菜单
export function delDepartment(id) {
    return request({
        url: '/basic/department-info/'+id,
        method: 'delete'
    })
}